1,681 research outputs found
Linear-Logic Based Analysis of Constraint Handling Rules with Disjunction
Constraint Handling Rules (CHR) is a declarative committed-choice programming
language with a strong relationship to linear logic. Its generalization CHR
with Disjunction (CHRv) is a multi-paradigm declarative programming language
that allows the embedding of horn programs. We analyse the assets and the
limitations of the classical declarative semantics of CHR before we motivate
and develop a linear-logic declarative semantics for CHR and CHRv. We show how
to apply the linear-logic semantics to decide program properties and to prove
operational equivalence of CHRv programs across the boundaries of language
paradigms
Optimal Union-Find in Constraint Handling Rules
Constraint Handling Rules (CHR) is a committed-choice rule-based language
that was originally intended for writing constraint solvers. In this paper we
show that it is also possible to write the classic union-find algorithm and
variants in CHR. The programs neither compromise in declarativeness nor
efficiency. We study the time complexity of our programs: they match the
almost-linear complexity of the best known imperative implementations. This
fact is illustrated with experimental results.Comment: 12 pages, 3 figures, to appear in Theory and Practice of Logic
Programming (TPLP
Terminological reasoning with constraint handling rules
Constraint handling rules (CHRs) are a flexible means to implement \u27user-defined\u27 constraints on top of existing host languages (like Prolog and Lisp). Recently, M. Schmidt-Schauß and G. Smolka proposed a new methodology for constructing sound and complete inference algorithms for terminological knowledge representation formalisms in the tradition of KLONE. We propose CHRs as a flexible implementation language for the consistency test of assertions, which is the basis for all terminological reasoning services.
The implementation results in a natural combination of three layers: (i) a constraint layer that reasons in well- understood domains such as rationals or finite domains, (ii) a terminological layer providing a tailored, validated vocabulary on which (iii) the application layer can rely. The flexibility of the approach will be illustrated by extending the formalism, its implementation and an application example (solving configuration problems) with attributes, a new quantifier and concrete domains
FreeCHR: An Algebraic Framework for CHR-Embeddings
We introduce the framework FreeCHR, which formalizes the embedding of
Constraint Handling Rules (CHR) into a host-language, using the concept of
initial algebra semantics from category theory, to establish a high-level
implementation scheme for CHR, as well as a common formalization for both
theory and practice. We propose a lifting of the syntax of CHR via an
endofunctor in the category Set and a lifting of the operational semantics,
using the free algebra, generated by the endofunctor. We then lift the very
abstract operational semantics of CHR into FreeCHR, and give proofs for
soundness and completeness w.r.t. their original definition.Comment: This is the extended version of a paper presented at the 7th
International Joint Conference on Rules and Reasoning (RuleML+RR 2023); minor
revision of section
- …